package com.qubi.exchange.mapper;

import com.qubi.exchange.message.OrderMessage;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;
import tk.mybatis.mapper.common.Mapper;

import java.util.List;

@Repository
public interface OrderMapper extends Mapper<OrderMessage> {

    List<OrderMessage> selectUnSuccessOrder(@Param("pair") String pair,@Param("index") int index,@Param("size") int size);

    int insertOrder(OrderMessage order);


    void batchUpdate(List<OrderMessage> orderList);

    List<OrderMessage> selectOrderByPair(@Param("pair")String pair, @Param("userId")String userId);
    public int insertByBatch(List<OrderMessage> orderList);
}
